CC=gcc
CFLAGS=-c -Wall -g -I/home/xgu/local/pupnp/include/upnp
LDFLAGS=-L/home/xgu/local/pupnp/lib -lixml -lthreadutil -lupnp

OBJECTS=$(SOURCES:.c=.o)
EXECUTABLE=tvdevice

SOURCES= \
   tv_device.c \
   tv_device_main.c \
   tv_util.c


all: $(SOURCES) $(EXECUTABLE)
	
$(EXECUTABLE): $(OBJECTS)
	$(CC) $(LDFLAGS) $(OBJECTS) -o $@

.c.o:
	$(CC) $(CFLAGS) $< -o $@

clean:
	rm *.o  tvdevice IUpnp*File.txt

